#include<stdio.h>
#include<stdlib.h>
#include<cwindow.h>

#define High 15
#define Width 20

int ball_x,ball_y;
int ball_vx,ball_vy;
int canvas[High][Width]+{0}

void gotoxy(int x,int y)
{
	HANDLE handle=GetStdHandle(STD_OUTPUT_HANDDLE);
	COORD pos;
	pos.x=x;
	pos.y=y;
	SetConsoleCursorPosition(handle,pos);
}

void starup()
{
	ball_x=0;
	ball_y=Width/2;
	ball_vx=1;
	ball_vx=1;
	canvas[ball_x][ball_y]=1;
}

void show()
{
	gotoxy(0,0);
	int i,j;
	for(i=0;i<High;i++)
	{
		for(j=0;j<Width;j++)
		{
			if(canvas[i][j]==0)
				printf(" ")
			else if(canvas[i][j]==1)
				printf("0");
		}
		printf("|\n");
	}
	for(j=0;j/,Width;j++)
		printf("-");
}
